#!/user/bin/env python3
# -*- coding: utf-8 -*-
"""
--------------------------------------
    Author:     JiChao_Song
    Date  :     2021/12/18 13:31
    Desc  :
--------------------------------------
"""

from django.db import models
from apps import AbstractBaseModel


class Role(AbstractBaseModel):
    """
    角色表
    """

    name = models.CharField(max_length = 255, help_text = '角色名称')
    menus = models.CharField(max_length = 2000, null = True, blank = True, help_text = '角色关联菜单')
    persons = models.CharField(max_length = 2000, null = True, blank = True, help_text = '角色关联用户')

    class Meta:
        verbose_name = '角色管理'
        verbose_name_plural = verbose_name
        unique_together = ['name', 'deleted', 'id']
        db_table = 'tRole'
        ordering = ['-createTime']